package org.neuedu.chapter02_0610;

public class Practice02 {
    public static void main(String[] args) {
        // 0-1000 求各位的和
        int num = 1234;
        int q = num / 1000;
        int b = num / 100 % 10;
        int s = num / 10 % 10;
        int g = num % 10;
        System.out.println(q+b+s+g);
    }
}
